//
//  CompareTableViewCell.m
//  CPU_Utility
//
//  Created by leonardo on 15/10/23.
//  Copyright © 2015年 leonardo. All rights reserved.
//

#import "CompareTableViewCell.h"
#import <UIImageView+WebCache.h>
@interface CompareTableViewCell(){
    
}

@property (weak, nonatomic) IBOutlet UIImageView *imagePicView;
@property (weak, nonatomic) IBOutlet UILabel *labelTitle;
@property (weak, nonatomic) IBOutlet UIButton *btnRemove;




@end
@implementation CompareTableViewCell{
    NSString * _proId ;
}

- (void)awakeFromNib {
    // Initialization code
   [super awakeFromNib];
}
-(void)configeWithName:(NSString *)name image:(NSString *)image id:(NSString *)proId{
    [_imagePicView sd_setImageWithURL:[NSURL URLWithString:image] placeholderImage:[UIImage imageNamed:@"wawa"]];
    
    //_imagePicView.contentMode = UIViewContentModeCenter;
    _labelTitle.text = name;
    [_btnRemove addTarget:self action:@selector(btnRemoveClicked:) forControlEvents:UIControlEventTouchUpInside];
    _proId = [[NSString alloc]initWithString:proId];
}
-(void)btnRemoveClicked:(UIButton *) sender {
    self.deleteCellBlock(_proId);
}




//- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
//    [super setSelected:selected animated:animated];
//
//    // Configure the view for the selected state
//}

@end
